-
Notifications
You must be signed in to change notification settings - Fork 97
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add workflow to run conda-store user journey tests #2895
base: main
Are you sure you want to change the base?
Conversation
8bb4c2a
to
814d7e8
Compare
depends on conda-incubator/conda-store#1040 |
814d7e8
to
b58c5c7
Compare
Since these tests depend on a live cluster, I suggest extending the already existing local integration tests with this extra check https://github.com/nebari-dev/nebari/blob/main/.github/workflows/test_local_integration.yaml -- since it uses CiRun under the hood you should not be affected by any flakiness of the GH runner in case of constrained resources. |
8d941b5
to
c108c2f
Compare
e18ebef
to
65896b1
Compare
d5f3827
to
8f11a28
Compare
3a6689a
to
40df38c
Compare
40df38c
to
42f24f1
Compare
903cf0e
to
bf97857
Compare
Hey @soapy1 no rush on this, but could you update us on this? Just considering adding to our next |
Heya @viniciusdc I've gotten a bit stuck on this one. I'm not able to find a way to pull an admin token for conda-store from nebari in order to run the tests (full notes in this comment - #2895 (comment)). Things that I've tried:
Other options I've considered (but haven't tried yet):
Definitely open to other ideas if you have a suggestion! |
I left a comment to your thread there, but basically I think your best options are those two:
nebari/src/_nebari/stages/kubernetes_services/__init__.py Lines 446 to 448 in ecaa94b
nebari/qhub/stages/input_vars.py Lines 271 to 278 in 81ff2fb
Lines 31 to 33 in ecaa94b
Used for example here:
try:
# Get user ID
users = keycloak_admin.get_users({"username": USER_TO_ADD})
if not users:
print(f"User '{USER_TO_ADD}' not found.")
exit(1)
user_id = users[0]["id"]
# Get group ID
groups = keycloak_admin.get_groups()
group_id = next((g["id"] for g in groups if g["name"] == "superadmin"), None)
if not group_id:
print(f"Group 'superadmin' not found.")
exit(1)
# Add user to group
keycloak_admin.group_user_add(user_id, group_id)
print(f"User '{USER_TO_ADD}' successfully added to 'superadmin' group.")
except KeycloakError as e:
print(f"Error: {e}") for the main API nebari/src/_nebari/keycloak.py Line 104 in ecaa94b
I wonder if this should be configured directly trough nebari's CLI anyway, we already have root access level credentials in the yaml, so it would not be a security overlook to allow the group in which the user will be created to appear as a custom flag as well.... |
ya, I was thinking about adding this. Something like
could make a v1 of this be something like only root users are allowed to set a role? |
d9b751c
to
66f1ffd
Compare
550fe91
to
88d000f
Compare
Reference Issues or PRs
fixes #2760
What does this implement/fix?
Put a
x
in the boxes that apply